1. Field of the Invention
The present invention relates to an image processing apparatus, an image forming system, and a computer program product.
2. Description of the Related Art
There is known a technique for performing a tone conversion using a tone curve to correct the tone of an image. The tone curve is a curve (or a straight line in some cases) in which output tones assigned to respective input tones are defined. By modifying the shape of this curve, a specific range of tones can be compressed or expanded. In general, a tone curve is defined by a few points, and these points are called control points. A tone curve is obtained by interpolation between control points to thereby draw the curve. A tone curve is widely used for the purpose of correcting an image because the brightness, contrast, and color balance, etc. of an image can be collectively corrected by using the tone curve.
A tone curve is usually generated manually; however, there are problems that there is a high degree of freedom in the generation of a tone curve, and high skill is required to appropriately generate a tone curve. For example, in a case of generating separate RGB tone curves for respective channels of an RGB image that are each expressed in 256 tones, at most 768 control points can be set. Furthermore, from the perspective of preventing collapse of an image, it is necessary to set control points to avoid blocked up shadows, blown out highlights, and tone jump, etc. To generate an optimum tone curve by setting a lot of control points appropriately, a user needs to be skilled or take a process of trial and error.
Furthermore, even if an optimum tone curve for a certain image can be generated, an optimum tone curve depends on a feature of an image; therefore, it is difficult to use a previously-generated tone curve for another image. For example, assume that images of the same scene are taken with different exposures, and a slightly dark image and a very dark image are obtained. When tone conversion is performed on these images by using the same tone curve for making a whole image brighter, it is easy to imagine that if a tone curve suitable for the former image is applied to the latter image, the latter image will not become sufficiently bright; on the other hand, if a tone curve suitable for the latter image is applied to the former image, the former image will become too bright. Furthermore, if an intermediate tone curve between two tone curves suitable for the images is used, it can be easily imagined that optimal results for both will not be obtained.
Therefore, how to generate an optimum tone curve for an image to be processed (hereinafter, referred to as a “processing object image”) and how to achieve the generation of the tone curve easily are important issues.
For example, a technology disclosed in Japanese Patent No. 2874657 is known as a conventional technology for easily performing image correction using a tone curve. In the technology disclosed in Japanese Patent No. 2874657, a correction pattern, which is a set of pieces of control information for highlight, medium tone, and shadow portions of an image, is stored to be associated with a color-related defect pattern. Then, when a user selects an arbitrary correction pattern and specifies a correction amount, a tone curve is calculated from control information for the selected correction pattern and the specified correction amount, and color conversion processing is performed on all pixels by use of the calculated tone curve.
However, in the conventional technology disclosed in Japanese Patent No. 2874657, it is necessary to select a correction pattern to be the basis of a tone curve from among multiple correction patterns and specify a correction amount. Therefore, an unskilled user cannot determine which correction pattern he/she should select and how much correction amount he/she should specify to calculate an optimum tone curve for correcting a processing object image, and still has to take a process of trial and error. Furthermore, in the conventional technology disclosed in Japanese Patent No. 2874657, a tone curve is calculated on the basis of a correction pattern prepared in advance; therefore, an optimum tone curve for a processing object image cannot always be calculated.
In view of the above, there is a need to provide an image processing apparatus, image forming system, and computer program product capable of easily generating an optimum tone curve for a processing object image.